# coding=utf-8
old_file_name = input('请输入要拷贝的文件名字：')
old_file = open(old_file_name, 'r')

if old_file:

    file_flag_num = old_file_name.rfind('.')
    if file_flag_num > 0:
        file_flag = old_file_name[file_flag_num:]

    new_file_name = old_file_name[:file_flag_num] + '[复印]' + file_flag

    new_file = open(new_file_name,'w')

    for lineContent in old_file.readlines():
        new_file.write(lineContent)

    new_file.close()
old_file.close()
